package com.ruoyi.web.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.web.mapper.QuantifyProfitMapper;
import com.ruoyi.web.domain.QuantifyProfit;
import com.ruoyi.web.service.IQuantifyProfitService;
import com.ruoyi.common.core.text.Convert;

/**
 * 量化收益Service业务层处理
 * 
 * @author ruoyi
 * @date 2023-05-19
 */
@Service
public class QuantifyProfitServiceImpl implements IQuantifyProfitService 
{
    @Autowired
    private QuantifyProfitMapper quantifyProfitMapper;

    /**
     * 查询量化收益
     * 
     * @param id 量化收益主键
     * @return 量化收益
     */
    @Override
    public QuantifyProfit selectQuantifyProfitById(Long id)
    {
        return quantifyProfitMapper.selectQuantifyProfitById(id);
    }

    /**
     * 查询量化收益列表
     * 
     * @param quantifyProfit 量化收益
     * @return 量化收益
     */
    @Override
    public List<QuantifyProfit> selectQuantifyProfitList(QuantifyProfit quantifyProfit)
    {
        return quantifyProfitMapper.selectQuantifyProfitList(quantifyProfit);
    }

    /**
     * 新增量化收益
     * 
     * @param quantifyProfit 量化收益
     * @return 结果
     */
    @Override
    public int insertQuantifyProfit(QuantifyProfit quantifyProfit)
    {
        return quantifyProfitMapper.insertQuantifyProfit(quantifyProfit);
    }

    /**
     * 修改量化收益
     * 
     * @param quantifyProfit 量化收益
     * @return 结果
     */
    @Override
    public int updateQuantifyProfit(QuantifyProfit quantifyProfit)
    {
        return quantifyProfitMapper.updateQuantifyProfit(quantifyProfit);
    }

    /**
     * 批量删除量化收益
     * 
     * @param ids 需要删除的量化收益主键
     * @return 结果
     */
    @Override
    public int deleteQuantifyProfitByIds(String ids)
    {
        return quantifyProfitMapper.deleteQuantifyProfitByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除量化收益信息
     * 
     * @param id 量化收益主键
     * @return 结果
     */
    @Override
    public int deleteQuantifyProfitById(Long id)
    {
        return quantifyProfitMapper.deleteQuantifyProfitById(id);
    }

    @Override
    public List<QuantifyProfit> selectQuantifyProfitSumList(QuantifyProfit quantifyProfit) {
        return quantifyProfitMapper.selectQuantifyProfitSumList(quantifyProfit);
    }
}
